using UnityEngine.UI;

/****************************************************
// 功能：弹出界面
// | Talk To [ 聊来改善地区金融服务环境，助力企业发展 ]
// | Copyright (c) 2021-2025 聊来 All rights reserved.
// | Licensed ( <a href="http://www.apache.org/licenses/LICENSE-2.0">聊来</a> )
// | @Author: 贯彻己道的云 <18970881148@qq.com>
// | DateTime: 2024/12/30 15:39:58
*****************************************************/

public class AlertWindow : BaseWindow
{
    private Text content;

    private void Awake()
    {
        content = FindChildTransform(transform, "content").GetComponent<Text>();
    }


    protected override void OnOpen(object arg)
    {
        base.OnOpen(arg);
        SetText(content, arg as string);
    }

    public void ClickCloseButton()
    {
        UIManager.Instance.ClosePopUp(WindowName.Alert);
    }

    public void SetContent(string txt)
    {
        SetText(content, txt);
    }
}